package com.hmall.client;

import com.hmall.item.Item;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(value = "itemservice")
public interface ItemClient {

    //search，order调用
    @GetMapping("/item/{id}")
    Item findById(@PathVariable("id") Long id);

    //search调用
    @DeleteMapping("/item/{id}")
    Item deleteById(@PathVariable("id") Long id);


}
